#include <stdio.h>
#include <string.h>

int main() {
    char password[] = "8888";
    char input[20];
    int attempts = 0;
    
    printf("Please enter password:");
    
    while (attempts < 3) {
        scanf("%s", input);
        
        if (strcmp(input, password) == 0) {
            printf("You are welcome!\n");
            return 0; // 口令正确，程序结束
        } else {
            printf("Wrong password!\n");
            attempts++;
            
            if (attempts < 3) {
                printf("Please enter again: ");
            } else {
                printf("You have entered three times! You are not welcome!\n");
                return 0; // 已经输入三次，程序结束
            }
        }
    }
    
    return 0;
}
